/**
 *@Author: QWP
 *@Description: 应急群相关接口
 *@Date 2024-08-06 19:04
 */
import request from "@/http";

// 分页列表查询
export const page = async (data: object) => {
  return await request.post({
    url: "/api/bizz/tGroupchat/page",
    data: data,
  });
};

// 新增
export const add = async (data: object) => {
  return await request.post({
    url: "/api/bizz/tGroupchat",
    data: data,
  });
};

// 修改
export const update = async (data: object) => {
  return await request.post({
    url: "/api/bizz/tGroupchat/update",
    data: data,
  });
};

// 删除
export const del = async (data: object) => {
  return await request.post({
    url: "/api/bizz/tGroupchat/delete",
    data: data,
    headersType: "application/x-www-form-urlencoded",
  });
};

// 单体查询
export const query = async (id: String) => {
  return await request.get({
    url: "/api/bizz/tGroupchat/details/" + id,
  });
};

// 根据登陆人查询创建群聊列表信息
export const queryGroup = async (data: object) => {
  return await request.post({
    url: "/api/bizz/tGroupchat/getGroupchat",
    data,
  });
};

// 导出
export const download = async (data: object) => {
  return await request.download1({
    url: "/api/bizz/tGroupchat/export",
    data,
  });
};
